Dynomotion

Group: DynoMotion Message: 5611 From: Henk Sterk Date: 8/28/2012
Subject: Tool Setup Screen Variable?
Attachments :
    Hi Tom,
     
    What can I do with the variable in " the Tool Setup Screen", when you lanch a program? (see attached jpg).
     
    Other question: is there a list of " persist.UserData[x] " varables that are avaiable for macro's?
     
    eg. persist.UserData[1] = new speed pushed down from GCode.
     
    Many thanks
     
    Henk
    Group: DynoMotion Message: 5614 From: Tom Kerekes Date: 8/28/2012
    Subject: Re: Tool Setup Screen Variable? [1 Attachment]
    Hi Henk,

    The "Var" parameter for macros in the KMotionCNC Tool Setup Screen specifies which persist Variables in KFLOP will be used to exchange information.

    For the Spindle Command S (which is implemented in the same way as a M Code Macro) the Spindle speed is set into the specified variable as a 32-bit floating point number.

    For the M6 Tool change macro the Tool number is placed into the Variable as a 32-bit integer

    Other Macros without any parameters will place the M code number into the variable as a 32-bit integer (ie M105 will set the value 105).

    For Macros with P Q R parameters will place the 3 parameters as 3 32-bit floats beginning at the specified Var.  see:

    http://dynomotion.com/Help/KMotionCNC/MCodesWithParams.htm

    Regarding which persist variables are used for what - at this point it is up to you to keep track of what Variables are used in your system.  There are a few defined in PC_DSP.h such as:

    #define PC_COMM_PERSIST 100  // First Persist Variable that is uploaded in status
    #define N_PC_COMM_PERSIST 8  // Number of Persist Variables that are uploaded in status


    #define MACH3_PROBE_STATUS_VAR 62
    #define MACH3_PROBE_RESULTS_VAR 50

    HTH
    TK

    Group: DynoMotion Message: 5617 From: Henk Sterk Date: 8/28/2012
    Subject: Re: Tool Setup Screen Variable?
    Thanks Tom.
     
    Understand, thats really powerful.
     
    Regards
     
    Henk

    On Tue, Aug 28, 2012 at 11:18 PM, Tom Kerekes <tk@...> wrote:
     

    Hi Henk,

    The "Var" parameter for macros in the KMotionCNC Tool Setup Screen specifies which persist Variables in KFLOP will be used to exchange information.

    For the Spindle Command S (which is implemented in the same way as a M Code Macro) the Spindle speed is set into the specified variable as a 32-bit floating point number.

    For the M6 Tool change macro the Tool number is placed into the Variable as a 32-bit integer

    Other Macros without any parameters will place the M code number into the variable as a 32-bit integer (ie M105 will set the value 105).

    For Macros with P Q R parameters will place the 3 parameters as 3 32-bit floats beginning at the specified Var.  see:


    Regarding which persist variables are used for what - at this point it is up to you to keep track of what Variables are used in your system.  There are a few defined in PC_DSP.h such as:

    #define PC_COMM_PERSIST 100  // First Persist Variable that is uploaded in status
    #define N_PC_COMM_PERSIST 8  // Number of Persist Variables that are uploaded in status


    #define MACH3_PROBE_STATUS_VAR 62
    #define MACH3_PROBE_RESULTS_VAR 50

    HTH
    TK